EXEC_NAME=shaderdemo
#INCLUDES=include
CC=g++
#GCC_OPTIONS=-Wall -pedantic -I$(INCLUDES)
#GCC_OPTIONS=-Wall -pedantic -I../../AngelCode_F2013/include
GCC_OPTIONS=-Wall -pedantic -Iinclude
#GL_OPTIONS=-lglut -lGLEW -lGL -lXmu -lXi -lXext -lX11 -lm
GL_OPTIONS=-lglut -lGLEW
COPTIONS=$(GCC_OPTIONS) $(GL_OPTIONS)


all: $(EXEC_NAME)

$(EXEC_NAME): initShader.o main.o GLObject3D.o ConcreteGLObject3D.o GLScene.o
	$(CC) $(GL_OPTIONS) -o $(EXEC_NAME) main.o initShader.o GLObject3D.o ConcreteGLObject3D.o GLScene.o

initShader.o: initShader.cpp
	$(CC) $(GCC_OPTIONS) -c initShader.cpp

main.o: main.cpp initShader.cpp GLObject3D.cpp ConcreteGLObject3D.cpp
	$(CC) $(GCC_OPTIONS) -c main.cpp

GLObject3D.o:	GLObject3D.cpp initShader.cpp
	$(CC) $(GCC_OPTIONS) -c GLObject3D.cpp

ConcreteGLObject3D.o:	ConcreteGLObject3D.cpp GLObject3D.cpp
	$(CC) $(GCC_OPTIONS) -c ConcreteGLObject3D.cpp

GLScene.o:	GLScene.cpp ConcreteGLObject3D.cpp GLObject3D.cpp
	$(CC) $(GCC_OPTIONS) -c GLScene.cpp


clean:
	rm -f *.o $(EXEC_NAME)

.PHONY: all clean
